free the context. (gdk_pixbuf__gif_image_load_animation): free the
authorJonathan Blandford <jrb@redhat.com>
Thu, 9 Mar 2000 00:11:30 +0000 (00:11 +0000)
committerJonathan Blandford <jrb@src.gnome.org>
Thu, 9 Mar 2000 00:11:30 +0000 (00:11 +0000)
2000-03-08  Jonathan Blandford  <jrb@redhat.com>

* gdk-pixbuf/io-gif.c (gdk_pixbuf__gif_image_load): free the context.
(gdk_pixbuf__gif_image_load_animation): free the context.

gdk-pixbuf/ChangeLog
gdk-pixbuf/io-gif.c

index 7faf7f195033e84f0017c2650d7c7e3ff432242c..9f91418a8e91d17e7f9e822e8368b99205b06900 100644 (file)
@@ -1,3 +1,8 @@
+2000-03-08  Jonathan Blandford  <jrb@redhat.com>
+
+       * gdk-pixbuf/io-gif.c (gdk_pixbuf__gif_image_load): free the context.
+       (gdk_pixbuf__gif_image_load_animation): free the context.
+
 2000-03-06  Arjan van de Ven <arjan@fenrus.demon.nl>
 
        * gdk-pixbuf/io-bmp.c: Fixed to pointer-bugs and a 
index 71c6288cb91b526f96ecb062af32621ab5aa83e6..c4397c497df634dee4de8cbf5af27385668ff57a 100644 (file)
@@ -1087,6 +1087,7 @@ GdkPixbuf *
 gdk_pixbuf__gif_image_load (FILE *file)
 {
        GifContext *context;
+       GdkPixbuf *pixbuf;
 
        g_return_val_if_fail (file != NULL, NULL);
 
@@ -1095,7 +1096,10 @@ gdk_pixbuf__gif_image_load (FILE *file)
 
        gif_main_loop (context);
 
-       return context->pixbuf;
+       pixbuf = context->pixbuf;
+       g_free (context);
+       return pixbuf;
 }
 
 gpointer
@@ -1197,6 +1201,7 @@ GdkPixbufAnimation *
 gdk_pixbuf__gif_image_load_animation (FILE *file)
 {
        GifContext *context;
+       GdkPixbufAnimation *animation;
 
        g_return_val_if_fail (file != NULL, NULL);
 
@@ -1208,6 +1213,8 @@ gdk_pixbuf__gif_image_load_animation (FILE *file)
        context->file = file;
 
        gif_main_loop (context);
-       
-       return context->animation;
+
+       animation = context->animation;
+       g_free (context);
+       return animation;
 }